package models

import "gorm.io/gorm"

type Nate struct {
	gorm.Model
	Title    string `gorm:"type:varchar(30);comment:'标题'"`
	Context  string `gorm:"type:varchar(255);comment:'正文'"`
	Tag      string `gorm:"type:varchar(255);comment:'标签'"`
	AuthorId int64  `gorm:"type:int(5);comment:'作者ID'"`
}

type Likes struct {
	gorm.Model
	UserId int64
	NateId int64
}

type Collect struct {
	gorm.Model
	UserId int64
	NateId int64
}

type Total struct {
	gorm.Model
	NateId       int64
	LikesCount   int64
	CollectCount int64
}

type ListCounts struct {
	NateId       int64
	Title        string
	Context      string
	Tag          string
	LikesCount   int64
	CollectCount int64
}
